A Simple Algorithm for Stable Minimum Storage Merging
نویسندگان
چکیده
We contribute to the research on stable minimum storage merging by introducing an algorithm that is particularly simply structured compared to its competitors. The presented algorithm performs O(m log( n m + 1)) comparisons and O((m + n) log m) assignments, where m and n are the sizes of the input sequences with m ≤ n. Hence, according to the lower bounds of merging the algorithm is asymptotically optimal regarding the number of comparisons. As central new idea we present a principle of symmetric splitting, where the start and end point of a rotation are computed by a repeated halving of two search spaces. This principle is structurally simpler than the principle of symmetric comparisons introduced earlier by Kim and Kutzner. It can be transparently implemented by few lines of Pseudocode. We report concrete benchmarks that prove the practical value of our algorithm.
منابع مشابه
Stable Minimum Storage Merging by Symmetric Comparisons
We introduce a new stable minimum storage algorithm for merging that needs O(m log( n m +1)) element comparisons, where m and n are the sizes of the input sequences with m ≤ n. According to the lower bound for merging, our algorithm is asymptotically optimal regarding the number of comparisons. The presented algorithm rearranges the elements to be merged by rotations, where the areas to be rota...
متن کاملIn situ, Stable Merging by Way of the Perfect Shuffle
We introduce a novel approach to the classical problem of in-situ, stable merging, where \in-situ" means the use of no more than O(log 2 n) bits of extra memory for lists of size n. Shuuemerge reduces the merging problem to the problem of realising the \perfect shuue" permutation, that is, the exact interleaving of two, equal length lists. The algorithm is recursive, using a logarithmic number ...
متن کاملOn Optimal and Efficient in Place Merging
We introduce a new stable in place merging algorithm that needs O(m log( n m +1)) comparisons and O(m+n) assignments. According to the lower bounds for merging our algorithm is asymptotically optimal regarding the number of comparisons as well as assignments. The stable algorithm is developed in a modular style out of an unstable kernel for which we give a definition in pseudocode. The literatu...
متن کاملMap-merging in Multi-robot Simultaneous Localization and Mapping Process Using Two Heterogeneous Ground Robots
In this article, a fast and reliable map-merging algorithm is proposed to produce a global two dimensional map of an indoor environment in a multi-robot simultaneous localization and mapping (SLAM) process. In SLAM process, to find its way in this environment, a robot should be able to determine its position relative to a map formed from its observations. To solve this complex problem, simultan...
متن کاملRatio Based Stable In-Place Merging
We investigate the problem of stable in-place merging from a ratio k = n m based point of view where m, n are the sizes of the input sequences with m ≤ n . We introduce a novel algorithm for this problem that is asymptotically optimal regarding the number of assignments as well as comparisons. Our algorithm uses knowledge about the ratio of the input sizes to gain optimality and does not stay i...
متن کامل